<?php

namespace app\model;

use think\Model;

class CrmBottomMenuOriginal extends Model
{

    protected $connection = 'mysql';

    protected $pk = 'id';

    protected $name = 'crm_bottom_menu_original';

    public static function getpagearray() {
        $data = self::field('url,title')->where(['status' => 1])
            ->order('sort asc')
            ->select()->toArray();

        foreach ($data as $k => $v) {
			$array[$k]['val'] = $v['url'];
			$array[$k]['key'] = $v['title'];
		}
        return $array;
    }
}
